package com.janj.service;

import com.janj.bean.Grade;
import com.janj.dao.GradeOnStudentMapper;
import com.janj.util.MyBatisUtils;
import org.apache.ibatis.session.SqlSession;

import java.util.List;

public class GradeOnStudentServiceImpl implements GradeOnStudentService {
    @Override
    public List<Grade> selectGradeOnStudent() {
        SqlSession session = MyBatisUtils.getSqlSession();
        GradeOnStudentMapper mapper = session.getMapper(GradeOnStudentMapper.class);
        List<Grade> array = mapper.selectGradeOnStudent();
        MyBatisUtils.close();

        return array;
    }
}
